package com.mindskip.xzs.viewmodel.admin.exam;

import com.alibaba.excel.annotation.ExcelIgnore;
import com.alibaba.excel.annotation.ExcelProperty;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.mindskip.xzs.utility.excel.BooleanConverter;
import com.mindskip.xzs.utility.excel.ExamTypeConverter;
import com.mindskip.xzs.utility.excel.LocalDateTimeConverter;
import lombok.Data;
import lombok.experimental.Accessors;

import java.io.Serializable;
import java.time.LocalDateTime;

@Data
@Accessors(chain = true)
public class FinishPagerRes implements Serializable {
    private static final long serialVersionUID = -7965052342062389267L;
    /*
     * exam
     */
    @ExcelIgnore
    private Integer examId;
    @ExcelProperty(value = "考试名称", index = 1)
    private String examName;

    /*
     * examPaper
     */
    @ExcelIgnore
    private Integer examPaperId;

    @ExcelProperty(value = "试卷名称", index = 4)
    private String paperName;
    @ExcelProperty(value = "考试类型", index = 2,converter = ExamTypeConverter.class)
    private Integer examType;

    /*
     * answer
     */
    @ExcelIgnore
    private Integer answerId;
    /**
     * 系统判定得分
     */
    @JsonIgnore
    @ExcelIgnore
    private Integer systemScoreInt;
    @ExcelIgnore
    private String systemScore;
    /**
     * 最终得分(千分制)
     */
    @JsonIgnore
    @ExcelIgnore
    private Integer userScoreInt;
    @ExcelProperty(value = "员工得分", index = 9)
    private String userScore;
    /**
     * 试卷总分
     */
    @JsonIgnore
    @ExcelIgnore
    private Integer paperScoreInt;
    @ExcelProperty(value = "试卷总分", index = 8)
    private String paperScore;
    /**
     * 做对题目数量
     */
    @ExcelProperty(value = "做对题目数", index = 7)
    private Integer questionCorrect;
    /**
     * 题目总数量
     */
    @ExcelProperty(value = "题目总数", index = 6)
    private Integer questionCount;
    /**
     * 做题时间(秒)
     */
    @ExcelProperty(value = "员工考试时长", index = 10)
    private String doTime;
    @JsonIgnore
    @ExcelIgnore
    private Integer doTimeSec;
    /**
     * 试卷状态(1待判分 2完成)
     */
    @ExcelIgnore
    private Integer judgeStatus;
    /**
     * 提交时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @ExcelProperty(value = "提交时间", index = 11, converter = LocalDateTimeConverter.class)
    private LocalDateTime submitTime;
    @ExcelProperty(value = "是否允许重复考试", index = 3,converter = BooleanConverter.class)
    private Boolean repetition;
    /**
     * user
     */
    @ExcelIgnore
    private Integer userId;
    @ExcelProperty(value = "答题员工", index = 5)
    private String userName;

    /**
     * 学分
     */
    @ExcelProperty(value = "学分", index = 12)
    private Integer credit;
}

